﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Data;

namespace Cashier_Model
{
    [Table(Tablename="admin")]
    public class Admin: BaseModel
    {     
        private Int64 id;

        [Table(Columnname = "id", Columntype = "bigint", Iskey = true, Iscondition = true, Fieldothername = "a", Isdeletefield = true)]
        public Int64 Id
        {
            get { return id; }
            set { id = value; }
        }

        private String enterpriseNo;

        [Table(Columnname = "enterprise_no", Columntype = "varchar", Iscondition = true, Fieldothername = "a", Isdeletefield = true)]
        public String EnterpriseNo
        {
            get { return enterpriseNo; }
            set { enterpriseNo = value; }
        }

        private String storeNo;

        [Table(Columnname="store_no", Columntype="varchar", Iscondition=true, Fieldothername="a")]
        public String StoreNo
        {
            get { return storeNo; }
            set { storeNo = value; }
        }
        
        private String username;

        [Table(Columnname = "username", Columntype = "varchar", Iscondition = true, Fieldothername = "a", Isupdatefield = true)]
        public String Username
        {
            get { return username; }
            set { username = value; }
        }
        
        private String password;

        [Table(Columnname = "password", Columntype = "varchar", Iscondition = true, Fieldothername = "a", Isupdatefield = true)]
        public String Password
        {
            get { return password; }
            set { password = value; }
        }
        
        private Int64 roleid;

        [Table(Columnname = "role_id", Columntype = "bigint", Iscondition = true, Fieldothername = "a", Isupdatefield = true)]
        public Int64 Roleid
        {
            get { return roleid; }
            set { roleid = value; }
        }
        
        private String name;

        [Table(Columnname = "name", Columntype = "varchar", Isupdatefield = true)]
        public String Name
        {
            get { return name; }
            set { name = value; }
        }
        
        private String mobile;

        [Table(Columnname = "mobile", Columntype = "varchar", Isupdatefield = true)]
        public String Mobile
        {
            get { return mobile; }
            set { mobile = value; }
        }

        private Boolean isadmin;

        [Table(Columnname = "is_admin", Columntype = "boolean", Isupdatefield = true)]
        public Boolean Isadmin
        {
            get { return isadmin; }
            set { isadmin = value; }
        }
        
        private String createdby;

        [Table(Columnname = "createdby", Columntype = "varchar")]
        public String Createdby
        {
            get { return createdby; }
            set { createdby = value; }
        }
        
        private DateTime createtime;

        [Table(Columnname = "createtime", Columntype = "datetime")]
        public DateTime Createtime
        {
            get { return createtime; }
            set { createtime = value; }
        }

        private String rolename;

        [Table(Columnname = "rolename", Columntype = "varchar")]
        public String Rolename
        {
            get { return rolename; }
            set { rolename = value; }
        }

        private DataTable rolePurviewtable;

        public DataTable RolePurviewtable
        {
            get { return rolePurviewtable; }
            set { rolePurviewtable = value; }
        }
    }
}
